﻿
<Serializable()>
Public Class CrystalReportMatadata
    Implements IComparable(Of CrystalReportMatadata)

    ''' <summary>
    ''' Fully qualified resource path of the report definition file
    ''' </summary>
    Public Property FullyQualifiedResourcePath As String

    ''' <summary>
    ''' The order (1st, 2nd, etc) that this report is shown on a menu
    ''' </summary>
    Public Property DisplayOrder As Integer

    ''' <summary>
    ''' The name of the report, as it will appear on a menu
    ''' </summary>
    Public Property DisplayName As Integer

    ''' <summary>
    ''' Indicates whether the report is active( ie, it should appear on the menu)
    ''' </summary>
    Public Property Active As Boolean

    Public Function CompareTo(ByVal other As CrystalReportMatadata) As Integer _
            Implements System.IComparable(Of CrystalReportMatadata).CompareTo

        If Me.DisplayOrder.CompareTo(other.DisplayOrder) = 0 Then
            Return Me.DisplayName.CompareTo(other.DisplayName)
        Else
            Return Me.DisplayOrder.CompareTo(other.DisplayOrder)
        End If
    End Function
End Class

Public Interface CrystalReportMatadataProvider

    Function getSystemReports() As List(Of CrystalReportMatadata)

End Interface

Public Interface CrystalReportMenuCreator

    Sub createMenu()

End Interface
